Cofs device
The cofs device is used to directly access files and directories of a Windows host system from a coLinux guest system. Please note: The cofs device is new in coLinux 0.6.2. It's still in the experimental phase and is very buggy! So don't blame us if it breaks your disk ;)... YES it is, it crashed my server when I tried to rename a file from within coLinux This and other crashes are fixed in coLinux 0.6.3. Please see Cofs in 0.6.3 for a description how to use it there. If you only need to transfer data to coLinux once, you can use an ISO image. You can use Windows software such as burnatonce (http://www.burnatonce.com) (it's free for non-commercial use) to create an ISO file (pretend you are going to burn your files onto CD, then just check the 'Image File' box on the Data CD Mastering dialog), then specify the resulting ISO file in your coLinux configuration file (block_device index="2" path="\DosDevices\c:\coLinux\myfiles.iso" enabled="true"), and then mount it from within coLinux (mount /dev/cobd2 /mnt -t iso9660). Obviously, this is one way Windows-to-Linux and is a real pain to do frequently, but it does let you transfer files without networking and without cofs. I could not find a documentation on the cofs device in this wiki, so I will relate what I found with Google: To get direct access to parts of the Windows host's file system, you may put in your colinux.xml. Now you can mount this virtual device with mount cofs0 /mnt/MYMOUNTPOINT -t cofs -o ro In the coLinux directory, there is a file named cofs.txt that describes cofs devices in much more detail. From cofs.txt the correct command is : mount -t cofs (cofs)XX(:path) (-o options) /mnt/point To grant read and write rights which enable access for all users, as well as to enable all users to mount the file system, place in /etc/fstab: cofs0:/ /mnt/cofs0 cofs user,noexec,dmask=0777,fmask=0666 0 0 ---- <LarsOlson> Or, using the command line configuration,CommandLineReference. let's say you have this setup The following coLinux command was used to start coLinux: colinux-daemon kernel=vmlinux hda1=root_fs cofs0=c:\temp Or Debian-3.0r2.ext3-mit-backports.1gb colinux-daemon kernel=vmlinux cobd0=Debian-3.0r2.ext3-mit-backports.1gb cofs0=c:\temp root=/dev/cobd0 eth0=slirp This maps cofs0 to c:\temp. Now, to mount c:\temp to be accessable in coLinux...run the following linux command mount -t cofs cofs0 /mnt/tempdir This is assuming that you have created a directory in /mnt/ called tempdir ---- pfalcon: Specifying cofs in XML work for me neither in 0.6.2 nor in 0.6.3pre13. Using gives: daemon: exit code 88010001 daemon: error - CO_RC_ERROR_ERROR, line 64, file colinux/user/config.o (64) Apparently, wrong tag. Using allows loading, but you cannot mount cofs device afterwards. I could get it working only with command-line params. ---- mavoke: The code in the sample xml is wrong. It states mode=flat but it should be type="flat". Change it to the latter and it will work. ---- srusek: Since the coLinux service is running as System, that means that when someone ssh's in they have access to the entire harddisk. ---- D0odman: I'm a bit new to this, but after MUCH mucking around, and getting MANY MANY tags wrong, I was able to get cofs to mount a couple directories within the Gentoo-colinux-x86-2004.3 image from the site: root=/dev/cobd/0 Both SEEM to mount fine, plus, I did some file moving, by copying files to the "files" directory within coLinux, and then seeing if I could delete them from within coLinux. Again, SEEMED to work fine. Another thing is that you're not able to access directories mounted within coLinux from windows. Hope this helps someone (I know it would've helped me four days ago :)) History: Added History Added link to CommandLineReference Added example for Debian-3.0r2.ext3-mit-backports.1gb coLinux 0.6.3 - 2006/04/07 ----MassTranslated on Sun Apr 23 17:35:42 UTC 2006 Category:Configuration